Skip to content

fix: allow display name in email from field#124

Merged
zzswang merged 2 commits into
mainfrom
fix/email-from-display-name
Jun 11, 2026
Merged

fix: allow display name in email from field#124
zzswang merged 2 commits into
mainfrom
fix/email-from-display-name

Conversation

@36node-walle

Copy link
Copy Markdown
Contributor

Summary

  • from 字段校验放宽为 @IsEmail({ allow_display_name: true }),支持带发件人显示名格式(如 "robot" <[email protected]>
  • 同步调整 SendEmailDtoEmailRecordDoc 两处校验,向后兼容纯邮箱地址
  • from 原样透传给 nodemailer/postmark,二者本身支持带显示名格式,传输层无需改动

Test plan

  • pnpm lint 通过
  • pnpm test 全部通过(51 passed)
  • 调用 @sendEmail 传入 "robot" <[email protected]>,确认收件方显示名正确
  • 传入纯邮箱地址,确认行为与原来一致

Made with Cursor

zzswang and others added 2 commits June 11, 2026 19:07
支持发件人地址带显示名格式(如 "robot" <[email protected]>),
通过 @isemail({ allow_display_name: true }) 放宽校验,向后兼容纯邮箱。

Co-authored-by: Cursor <[email protected]>
@github-actions

Copy link
Copy Markdown
Contributor

sdk version 2.27.0-pr-124-784097a775

## for js/ts project
pnpm add @36node/[email protected]

@zzswang zzswang merged commit deb1398 into main Jun 11, 2026
3 checks passed
@zzswang zzswang deleted the fix/email-from-display-name branch June 11, 2026 11:28
zzswang pushed a commit that referenced this pull request Jun 11, 2026
🤖 I have created a release *beep* *boop*
---


## [2.27.1](v2.27.0...v2.27.1)
(2026-06-11)


### Bug Fixes

* allow display name in email from field
([#124](#124))
([deb1398](deb1398))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants